package template

import "fmt"

type WorkerInterface interface {
	Getup()
	Work()
	Sleep()
}

type Worker struct {
	WorkerInterface
}

func NewWorker(w WorkerInterface) *Worker {
	return &Worker{w}
}

func (w *Worker) Daily() {
	w.Getup()
	w.Work()
	w.Sleep()
}

type Coder struct{}

func (c *Coder) Getup() {
	fmt.Println("coder is getting up")
}

func (c *Coder) Work() {
	fmt.Println("coder is working")
}

func (c *Coder) Sleep() {
	fmt.Println("coder is sleeping")
}

type Manager struct{}

func (m *Manager) Getup() {
	fmt.Println("manager is getting up")
}

func (m *Manager) Work() {
	fmt.Println("manager is working")
}

func (m *Manager) Sleep() {
	fmt.Println("manager is sleeping")
}
